import request from "@/utils/request";

// 添加会员
export const addVipApi = (params:any):Promise<AddVipApiRes>=>request.post('/vip/addvip',params)
// 获取会员
export const getVipApi = (params:any):Promise<GetVipApiRes>=>request.get(`/vip/getvip?pageSize=${params.pageSize}&&pageNum=${params.pageNum}&&belongToShop=${params.belongToShop}`)
// 禁用会员
export const deleteVipApi = (params:deleteVipReq):Promise<deleteVipRes>=>request.post('/vip/deletevip',params)
// 修改会员
export const updateVipApi = (params:updateVipReq):Promise<updateVipRes>=>request.post('/vip/updatevip',params)
// 搜索会员
export const searchVipApi = (params:searchVipReq):Promise<searchVipRes>=>request.post('/vip/searchvip',params)
// 今日过生
export const getTodayBornApi = ():Promise<any>=>request.get('/vip/gettodayborn')
// 今日到期
export const getTodayExpiresApi = ():Promise<any>=>request.get('/vip/gettodayexpires')
// 今日新增
export const getTodayAddVipApi = ():Promise<any>=>request.get('/vip/gettodayaddvip')
// 30未消费
export const getThirtyNotConsumApi = ():Promise<any>=>request.get('/vip/getthirtynotconsum')
// 获取会员等级
export const getVipRankApi = (params:any):Promise<any>=>request.get(`/vip/getviprank?pageSize=${params.pageSize}&&pageNum=${params.pageNum}&&belongToShop=${params.belongToShop}`)
// 添加会员等级
export const addVipRankApi = (params:any):Promise<any>=>request.post('/vip/addviprank',params)
// 更新会员等级
export const updateVipRankApi = (params:any):Promise<any>=>request.post('/vip/updateviprank',params)
// 删除会员等级
export const delVipRankApi = (params:any):Promise<any>=>request.post('/vip/delviprank',params)
// 删除会员等级
export const searchVipRankApi = (params:any):Promise<any>=>request.post('/vip/searchviprank',params)